With the rapid development of the terminal industry, a terminal device can provide increasing functions. An existing terminal device is equipped with a large quantity of sensors, for example, a Global Positioning System (GPS) sensor, an acceleration sensor, an ambient light sensor, a sound sensor, a proximity sensor, a compass, and a gyroscope. A tiny change in each sensor may be captured in real time using these sensors on the terminal device, so as to acquire, by means of analysis, context information of a user using the terminal device, that is, a current status and/or a current location of the user. For example, whether an activity status of the user is walking, running, or riding may be analyzed by means of calculation using an acceleration parameter acquired by the acceleration sensor, and whether a location in which the user is located is in the office or at home may be analyzed by means of statistics collection using a GPS, WiFi network information, and base station cell information of a telephone network.
With the promotion of machine learning and data mining technologies, related information of a person and an environment may be easily acquired and analyzed. Subsequently, context awareness calculation emerges. By means of human-computer interaction or using a sensor, the context awareness calculation is provided for a computing device to calculate by means of analysis and predict context information such as an environment and activities of the person and the device, and makes the computing device automatically react accordingly. Therefore, in the terminal device, by means of context awareness calculation and using context information acquired by the terminal device by means of analysis, the device may also be made to automatically react accordingly.
In many service applications of the terminal device, a color ring back tone service, that is, a customized ring back tone service, is a widely used service and is a service in which a called user sets a color ring back tone with a special sound effect (music, a song, a story plot, and a character dialog) for another calling user that calls a mobile telephone of the called user. In an existing color ring back tone service, a color ring back tone is generally set to fixed color ring back tone music. Alternatively, if the called user intends to use different color ring back tone music to express a current status of the user and let a caller have relatively favorable experience, different color ring back tone music needs to be played by means of manual setting by the user in the terminal device in different contexts. However, the different color ring back tone music is manually set by the user in the different contexts, and when the user has multiple activities or a location is frequently changed, manual setting of a color ring back tone is tedious and inconvenient, which leads to extremely low user experience of the terminal device.